/**
 * Copyright (c) 2025 Bytedance Ltd. and/or its affiliates
 * 
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * 
 *     http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 **/

.chat-room {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 70px);
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  border-bottom: 1px solid #eee;
  padding-bottom: 10px;
}

.chat-title {
  font-size: 24px;
  color: #333;
  margin: 0;
}

.chat-status {
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 14px;
}

.chat-body {
  display: flex;
  flex: 1;
  gap: 20px;
  overflow: hidden;
}

.chat-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  border: 1px solid #eee;
  border-radius: 8px;
  overflow: hidden;
}

.message-list {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  background-color: #f9f9f9;
}

.chat-input-container {
  display: flex;
  padding: 15px;
  background-color: white;
  border-top: 1px solid #eee;
}

.message-input {
  flex: 1;
  padding: 10px 15px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 16px;
  resize: none;
  min-height: 44px;
}

.send-button {
  margin-left: 10px;
  padding: 0 20px;
  background-color: #4a90e2;
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.send-button:hover {
  background-color: #3a7bc8;
}

.chat-sidebar {
  width: 250px;
  border: 1px solid #eee;
  border-radius: 8px;
  overflow: hidden;
}

.participant-header {
  padding: 15px;
  background-color: #f5f5f5;
  border-bottom: 1px solid #eee;
}

.participant-title {
  margin: 0;
  font-size: 18px;
  color: #333;
}

.participant-list {
  padding: 15px;
  overflow-y: auto;
  max-height: calc(100% - 50px);
}

.participant {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
  padding: 8px;
  border-radius: 4px;
  background-color: #f9f9f9;
}

.participant-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: #4a90e2;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  margin-right: 10px;
}

.participant-name {
  font-size: 14px;
}

.message {
  margin-bottom: 15px;
  display: flex;
  flex-direction: column;
}

.message-sender {
  font-weight: bold;
  font-size: 14px;
  margin-bottom: 5px;
  color: #555;
}

.message-content {
  padding: 10px 15px;
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  max-width: 80%;
  align-self: flex-start;
  word-break: break-word;
}

.message.own-message .message-content {
  background-color: #dcf8c6;
  align-self: flex-end;
}

.message-timestamp {
  font-size: 12px;
  color: #888;
  margin-top: 5px;
  align-self: flex-start;
}

.message.own-message .message-timestamp {
  align-self: flex-end;
}

.back-button {
  padding: 8px 15px;
  background-color: #f0f0f0;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  cursor: pointer;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: background-color 0.2s;
}

.back-button:hover {
  background-color: #e0e0e0;
}